<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>克隆节点和删除节点</title>
</head>
<body>
    <ul>
        <li>1</li>
        <li>2</li>
        <li>3</li>
    </ul>

    <script>
        const ul = document.querySelector('ul')
        // 克隆节点并添加到 ul
        ul.appendChild(ul.children[0].cloneNode(true))
        // 删除节点（父亲删儿子）
        ul.removeChild(ul.children[0])
    </script>
</body>
</html>